home *** CD-ROM | disk | FTP | other *** search
- Path: access1.digex.net!not-for-mail
- From: ell@access1.digex.net (Ell)
- Newsgroups: comp.lang.c++
- Subject: Re: Virtuals in constructor
- Date: 22 Feb 1996 01:58:05 GMT
- Organization: The Universe
- Message-ID: <4ggijd$931@news4.digex.net>
- References: <312A3A72.688D@scopus.ch>
- NNTP-Posting-Host: access1.digex.net
- X-Newsreader: TIN [UNIX 1.3 950824BETA PL0]
-
- Fabienne Guinnard (guinnard_f@scopus.ch) wrote:
- : Hi,
- :
- : does anyone know why the following code doesn't work ?
- :
- : Run-time error: pure virtual function called
- :
- : class A
- : {
- : public:
- : A(VOID) { Method(); }
- :
- : virtual VOID Method(VOID) = 0;
- : };
-
- According to the '92 ARM, it is undefined to call a pure virtual function
- of a class from its constructor.
-
- Elliott
-